#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
#include <sys/stat.h>
#include <sys/types.h>
#include <sys/ioctl.h>
#include <stdint.h>
#include <sys/mman.h>
#include <fcntl.h>
#include <stdbool.h>
#include <errno.h>
#include <string.h>
#include <signal.h>
#include <dlfcn.h>
#include <pthread.h>
#include <linux/fb.h>

int main(int argc, char const *argv[])
{
    mkfifo("BPID",0666);
    int fifo = open("BPID",O_RDWR);
    pid_t BPID;
    read(fifo,&BPID,sizeof(pid_t));
    while (1)
    {
        union sigval val;
        val.sival_int =rand()%20;
        sigqueue(BPID,SIGUSR1,val);
        sleep(1);
        
    }
    
    return 0;
}
